package com.admin4j.server.system.convert;

import com.admin4j.server.system.entity.SysUser;
import com.admin4j.server.system.entity.vo.SysUserLoginInfoVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;

/**
 * @author andanyang
 * @since 2023/11/7 14:59
 */
@Mapper
public interface SysUserConvert {

    SysUserConvert INSTANCE = Mappers.getMapper(SysUserConvert.class);

    @Mapping(source = "userName", target = "username")
    SysUserLoginInfoVO convert(SysUser sysUser);
}
